package fr.charlott.core.repository.model;

public enum TailleHaut implements Taille{
	ND("Non defini"), 
	//Taille haut
	T80A("80 A"), T85A("85 A"),
	T80B("80 B"), T85B("85 B"), T90B("90 B"), T95B("95 B"),
	T85C("85 C"), T90C("90 C"), T95C("95 C"), T100C("100 C"),
	T85D("85 D"), T90D("90 D"), T95D("95 D");
	
	private String nom;
	
	private TailleHaut(String nom){
		this.nom = nom;
	}
	
	@Override
	public String getNom() {
		return nom;
	}

	public void setNom(String nom) {
		this.nom = nom;
	}
	
	@Override
	public String toString(){
		return nom;
	}
	
	public static TailleHaut getEnumForValue(String value){
		TailleHaut[] values = TailleHaut.values();
		String enumValue = null;
		for(TailleHaut eachValue : values){
			enumValue = eachValue.toString();
			if (enumValue.equalsIgnoreCase(value) || enumValue.equalsIgnoreCase(value.trim())){
				return eachValue;
			}
		}
		return TailleHaut.ND;
	}
}
